package cn.wolfcode.feign.fallback;

import cn.wolfcode.common.web.Result;
import cn.wolfcode.domain.Product;
import cn.wolfcode.feign.ProductApi;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 *为商品服务提供的容错类
 */
@Component
public class ProductFallBack implements ProductApi {

    @Override
    public Result<List<Product>> getProducts(List<Long> ids) {
        return Result.defaultError();
    }

    @Override
    public Result<Product> getProductById(Long productId) {
        return Result.defaultError();
    }
}
